public class Main {
    public static void main(String[] args) {
        Leg leg1 = new Leg("长");
        Eye eye1 = new Eye("蓝色");
        Tail tail1 = new Tail("短");

        Leg leg2 = new Leg("短");
        Eye eye2 = new Eye("黑色");
        Tail tail2 = new Tail("长");

        bear bear1 = new bear("熊大",leg1,eye1,tail1);
        bear bear2 = new bear("熊二",leg2,eye2,tail2);

        bear1.eat();
        bear2.eat();

        bear1.watch(bear1);
        bear2.watch(bear2);

        bear1.legmove(bear1);
        bear2.legmove(bear2);
    }
}


 abstract class Animal{
    String name;

    Animal(){

    }

    Animal(String name){
        this.name=name;
    }

    public abstract void eat();
}



 class bear extends Animal{

    Leg leg;
    Eye eye;
    Tail tail;

    public bear() {

    }

    public bear(String name,Leg leg,Eye eye,Tail tail) {
        super.name = name;
        this.leg=leg;
        this.eye=eye;
        this.tail=tail;
    }


    @Override
    public void eat() {
        System.out.println(super.name + "吃");

    }

    public void watch(Animal animal) {
        this.eye.watch(animal);
    }

    public void legmove(Animal animal) {
        this.leg.legmove(animal);
    }


}


 class Eye implements IWatch{

    String color;

    public Eye(){

    }

    public Eye(String color){
        this.color = color;
    }


    @Override
    public void watch(Animal animal) {
        System.out.println(animal.name + "看");
    }

}

 interface IMove {
    void move();
}


 interface IWatch {
    void watch(Animal animal);
}



 class Leg implements LegMove{

    String length;

    public Leg(){

    }

    public Leg(String length){
        this.length = length;
    }

    public void move() {
        System.out.println();
    }

    @Override
    public void legmove(Animal animal) {
        System.out.println(animal.name + "跑");
    }


}

 interface LegMove {
    void legmove(Animal animal);
}


 class Nose implements IMove{

    String size;

    public Nose(){

    }

    public Nose(String size){
        this.size = size;
    }


    @Override
    public void move() {
        // TODO Auto-generated method stub

    }

}

class Skin implements IMove{

    @Override
    public void move() {
        // TODO Auto-generated method stub

    }

}

 class Tail implements IMove{

    String length;

    public Tail(){

    }

    public Tail(String length){
        this.length = length;
    }

    @Override
    public void move() {

    }

    public void UseTail(Tail tail,String style){

    }
}


